package com.roy.spring.service;

import com.roy.spring.entity.User;
import com.roy.spring.entity.UserRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by admin on 18-1-13.
 */
@Service
public class UserService extends BaseService<User, UserRepository> {
    @Autowired
    public UserService(UserRepository userRepository) {
        super(userRepository);
    }

    public List<User> findByUsername(String username) {
        return getRepo().findByUsername(username);
    }
}
